
use num_enum::{IntoPrimitive, TryFromPrimitive};


///
/// 信息类型标志
/// See B.3.5.2.2 Table B.3
///
#[derive(Debug, Copy, Clone, PartialEq, Eq, TryFromPrimitive, IntoPrimitive)]
#[repr(u8)]
pub enum UploadDataType {
    /// 整车数据
    Vehicle = 0x01,
    /// 驱动电机数据
    DriveMotor = 0x02,
    /// 燃料电池数据
    FuelCell = 0x03,
    /// 发动机数据
    Engine = 0x04,
    /// 车辆位置
    Location = 0x05,
    /// 极值数据
    ExtremeValue = 0x06,
    /// 报警数据
    Alarm = 0x07,
    /// 可充电储能装置电压数据
    RechargeableEnergyStorageVoltage = 0x08,
    /// 可充电储能装置温度数据
    RechargeableEnergyStorageTemperature = 0x09,
    /// 用户自定义数据-A
    UserCustomA = 0x80,
}
